<div style="clear:both;margin:1em 0px;">

	<?php 
	
		$fields = array();

		$fields []= (object) array('label' => 'Name','name' => 'name');
		$fields []= (object) array('itemRenderer' => '<input type="hidden" name="folder" value="'.$folder.'" />');
		$fields []= (object) array('itemRenderer' => '<input type="hidden" name="ref" value="'.EbController::$request->url.'" />');
		$fields []= (object) array('label' => 'Media:','itemRenderer' => '<input type="file" name="media" />');
		
		eb_widget('form',array('action' => '/Media/UploadMedia.do','enctype' => 'multipart/form-data','method' => 'POST','fields' => $fields));
	
	?>
	
	
	<?php 
	
//		$fields = array();
//
//		$fields []= (object) array('label' => 'Name','name' => 'name');
//		$fields []= (object) array('itemRenderer' => '<input type="hidden" name="folder" value="'.$folder.'" />');
//		$fields []= (object) array('itemRenderer' => '<input type="hidden" name="ref" value="'.EbController::$request->url.'" />');
//		$fields []= (object) array('label' => 'Code:','itemRenderer' => '<textarea rows="5" cols="20" name="code"></textarea>');
//		
//		eb_widget('form',array('action' => '/Media/PasteEmbeddedCode.do','fields' => $fields));
	
	?>
	
</div>